/**
 *
 */
import OpenApi;
import OpenApi.OpenApiUtil;

extends OpenApi;


init(config: OpenApiUtil.Config){
  super(config);
  @endpointRule = '';
  
  checkConfig(config);
  @endpoint = getEndpoint('dfs', @regionId, @endpointRule, @network, @suffix, @endpointMap, @endpoint);
}

function getEndpoint(productId: string, regionId: string, endpointRule: string, network: string, suffix: string, endpointMap: map[string]string, endpoint: string) throws: string{
  if (!$isNull(endpoint)) {
    return endpoint;
  }
  
  if (!$isNull(endpointMap) && !$isNull(endpointMap[regionId])) {
    return endpointMap[regionId];
  }
  return OpenApiUtil.getEndpointRules(productId, regionId, endpointRule, network, suffix);
}

model AttachVscMountPointRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIds?: [ string ](name='InstanceIds', example='["ecs-instance1", "ecs-instance2"]'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
  useAssumeRoleChkServerPerm?: boolean(name='UseAssumeRoleChkServerPerm'),
  vscIds?: [ string ](name='VscIds'),
  vscType?: string(name='VscType'),
}

model AttachVscMountPointShrinkRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIdsShrink?: string(name='InstanceIds', example='["ecs-instance1", "ecs-instance2"]'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
  useAssumeRoleChkServerPerm?: boolean(name='UseAssumeRoleChkServerPerm'),
  vscIdsShrink?: string(name='VscIds'),
  vscType?: string(name='VscType'),
}

model AttachVscMountPointResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model AttachVscMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: AttachVscMountPointResponseBody(name='body'),
}

/**
 * @description ****
 *
 * @param tmpReq AttachVscMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return AttachVscMountPointResponse
 */
async function attachVscMountPointWithOptions(tmpReq: AttachVscMountPointRequest, runtime: $RuntimeOptions): AttachVscMountPointResponse {
  tmpReq.validate();
  var request = new AttachVscMountPointShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.instanceIds)) {
    request.instanceIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.instanceIds, 'InstanceIds', 'json');
  }
  if (!$isNull(tmpReq.vscIds)) {
    request.vscIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.vscIds, 'VscIds', 'json');
  }
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.instanceIdsShrink)) {
    query['InstanceIds'] = request.instanceIdsShrink;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  if (!$isNull(request.useAssumeRoleChkServerPerm)) {
    query['UseAssumeRoleChkServerPerm'] = request.useAssumeRoleChkServerPerm;
  }
  if (!$isNull(request.vscIdsShrink)) {
    query['VscIds'] = request.vscIdsShrink;
  }
  if (!$isNull(request.vscType)) {
    query['VscType'] = request.vscType;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'AttachVscMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @description ****
 *
 * @param request AttachVscMountPointRequest
 * @return AttachVscMountPointResponse
 */
async function attachVscMountPoint(request: AttachVscMountPointRequest): AttachVscMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return attachVscMountPointWithOptions(request, runtime);
}

model BindVscMountPointAliasRequest {
  aliasPrefix?: string(name='AliasPrefix', description='This parameter is required.', example='sdfe'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
}

model BindVscMountPointAliasResponseBody = {
  mountPointAlias?: string(name='MountPointAlias', example='sdfe'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model BindVscMountPointAliasResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: BindVscMountPointAliasResponseBody(name='body'),
}

/**
 * @param request BindVscMountPointAliasRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return BindVscMountPointAliasResponse
 */
async function bindVscMountPointAliasWithOptions(request: BindVscMountPointAliasRequest, runtime: $RuntimeOptions): BindVscMountPointAliasResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.aliasPrefix)) {
    query['AliasPrefix'] = request.aliasPrefix;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'BindVscMountPointAlias',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request BindVscMountPointAliasRequest
 * @return BindVscMountPointAliasResponse
 */
async function bindVscMountPointAlias(request: BindVscMountPointAliasRequest): BindVscMountPointAliasResponse {
  var runtime = new $RuntimeOptions{};
  return bindVscMountPointAliasWithOptions(request, runtime);
}

model CreateAccessGroupRequest {
  accessGroupName?: string(name='AccessGroupName', description='This parameter is required.', example='my-online-cluster-policy'),
  description?: string(name='Description'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  networkType?: string(name='NetworkType', description='This parameter is required.', example='VPC'),
}

model CreateAccessGroupResponseBody = {
  accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateAccessGroupResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateAccessGroupResponseBody(name='body'),
}

/**
 * @param request CreateAccessGroupRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateAccessGroupResponse
 */
async function createAccessGroupWithOptions(request: CreateAccessGroupRequest, runtime: $RuntimeOptions): CreateAccessGroupResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupName)) {
    query['AccessGroupName'] = request.accessGroupName;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.networkType)) {
    query['NetworkType'] = request.networkType;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateAccessGroup',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request CreateAccessGroupRequest
 * @return CreateAccessGroupResponse
 */
async function createAccessGroup(request: CreateAccessGroupRequest): CreateAccessGroupResponse {
  var runtime = new $RuntimeOptions{};
  return createAccessGroupWithOptions(request, runtime);
}

model CreateAccessRuleRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  description?: string(name='Description'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  networkSegment?: string(name='NetworkSegment', description='This parameter is required.', example='192.0.2.0/24'),
  priority?: int32(name='Priority', description='This parameter is required.', example='2'),
  RWAccessType?: string(name='RWAccessType', description='This parameter is required.', example='RDWR'),
}

model CreateAccessRuleResponseBody = {
  accessRuleId?: string(name='AccessRuleId', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateAccessRuleResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateAccessRuleResponseBody(name='body'),
}

/**
 * @param request CreateAccessRuleRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateAccessRuleResponse
 */
async function createAccessRuleWithOptions(request: CreateAccessRuleRequest, runtime: $RuntimeOptions): CreateAccessRuleResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.networkSegment)) {
    query['NetworkSegment'] = request.networkSegment;
  }
  if (!$isNull(request.priority)) {
    query['Priority'] = request.priority;
  }
  if (!$isNull(request.RWAccessType)) {
    query['RWAccessType'] = request.RWAccessType;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateAccessRule',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request CreateAccessRuleRequest
 * @return CreateAccessRuleResponse
 */
async function createAccessRule(request: CreateAccessRuleRequest): CreateAccessRuleResponse {
  var runtime = new $RuntimeOptions{};
  return createAccessRuleWithOptions(request, runtime);
}

model CreateFileSystemRequest {
  dataRedundancyType?: string(name='DataRedundancyType', example='LRS'),
  dedicatedClusterId?: string(name='DedicatedClusterId'),
  description?: string(name='Description'),
  fileSystemName?: string(name='FileSystemName', description='This parameter is required.', example='MyFirstHDFS'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  partitionNumber?: int32(name='PartitionNumber', example='0'),
  protocolType?: string(name='ProtocolType', description='This parameter is required.', example='HDFS'),
  provisionedThroughputInMiBps?: long(name='ProvisionedThroughputInMiBps', example='1024'),
  spaceCapacity?: long(name='SpaceCapacity', description='This parameter is required.', example='1024'),
  storageSetName?: string(name='StorageSetName', example='AligroupStorageSet'),
  storageType?: string(name='StorageType', description='This parameter is required.', example='STANDARD'),
  throughputMode?: string(name='ThroughputMode', example='Standard'),
  zoneId?: string(name='ZoneId', example='cn-hangzhou-b'),
}

model CreateFileSystemResponseBody = {
  fileSystemId?: string(name='FileSystemId'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateFileSystemResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateFileSystemResponseBody(name='body'),
}

/**
 * @param request CreateFileSystemRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateFileSystemResponse
 */
async function createFileSystemWithOptions(request: CreateFileSystemRequest, runtime: $RuntimeOptions): CreateFileSystemResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.dataRedundancyType)) {
    query['DataRedundancyType'] = request.dataRedundancyType;
  }
  if (!$isNull(request.dedicatedClusterId)) {
    query['DedicatedClusterId'] = request.dedicatedClusterId;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemName)) {
    query['FileSystemName'] = request.fileSystemName;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.partitionNumber)) {
    query['PartitionNumber'] = request.partitionNumber;
  }
  if (!$isNull(request.protocolType)) {
    query['ProtocolType'] = request.protocolType;
  }
  if (!$isNull(request.provisionedThroughputInMiBps)) {
    query['ProvisionedThroughputInMiBps'] = request.provisionedThroughputInMiBps;
  }
  if (!$isNull(request.spaceCapacity)) {
    query['SpaceCapacity'] = request.spaceCapacity;
  }
  if (!$isNull(request.storageSetName)) {
    query['StorageSetName'] = request.storageSetName;
  }
  if (!$isNull(request.storageType)) {
    query['StorageType'] = request.storageType;
  }
  if (!$isNull(request.throughputMode)) {
    query['ThroughputMode'] = request.throughputMode;
  }
  if (!$isNull(request.zoneId)) {
    query['ZoneId'] = request.zoneId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateFileSystem',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request CreateFileSystemRequest
 * @return CreateFileSystemResponse
 */
async function createFileSystem(request: CreateFileSystemRequest): CreateFileSystemResponse {
  var runtime = new $RuntimeOptions{};
  return createFileSystemWithOptions(request, runtime);
}

model CreateMountPointRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  networkType?: string(name='NetworkType', description='This parameter is required.', example='VPC'),
  usePerformanceMode?: boolean(name='UsePerformanceMode'),
  vSwitchId?: string(name='VSwitchId', description='This parameter is required.', example='vsw-iq8fymi327krd14mt****'),
  vpcId?: string(name='VpcId', description='This parameter is required.', example='vpc-iq8hhsk3ymzv9m4wn****'),
}

model CreateMountPointResponseBody = {
  mountPointId?: string(name='MountPointId'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateMountPointResponseBody(name='body'),
}

/**
 * @param request CreateMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateMountPointResponse
 */
async function createMountPointWithOptions(request: CreateMountPointRequest, runtime: $RuntimeOptions): CreateMountPointResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.networkType)) {
    query['NetworkType'] = request.networkType;
  }
  if (!$isNull(request.usePerformanceMode)) {
    query['UsePerformanceMode'] = request.usePerformanceMode;
  }
  if (!$isNull(request.vSwitchId)) {
    query['VSwitchId'] = request.vSwitchId;
  }
  if (!$isNull(request.vpcId)) {
    query['VpcId'] = request.vpcId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request CreateMountPointRequest
 * @return CreateMountPointResponse
 */
async function createMountPoint(request: CreateMountPointRequest): CreateMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return createMountPointWithOptions(request, runtime);
}

model CreateQosPolicyRequest {
  description?: string(name='Description'),
  federationId?: string(name='FederationId'),
  fileSystemId?: string(name='FileSystemId'),
  flowIds?: [ int32 ](name='FlowIds'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
  maxIOBandWidth?: long(name='MaxIOBandWidth'),
  maxIOps?: long(name='MaxIOps'),
  maxMetaQps?: long(name='MaxMetaQps'),
  zoneIds?: [ string ](name='ZoneIds'),
}

model CreateQosPolicyShrinkRequest {
  description?: string(name='Description'),
  federationId?: string(name='FederationId'),
  fileSystemId?: string(name='FileSystemId'),
  flowIdsShrink?: string(name='FlowIds'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
  maxIOBandWidth?: long(name='MaxIOBandWidth'),
  maxIOps?: long(name='MaxIOps'),
  maxMetaQps?: long(name='MaxMetaQps'),
  zoneIdsShrink?: string(name='ZoneIds'),
}

model CreateQosPolicyResponseBody = {
  errorMessages?: string(name='ErrorMessages'),
  qosPolicyId?: string(name='QosPolicyId'),
  requestId?: string(name='RequestId'),
}

model CreateQosPolicyResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateQosPolicyResponseBody(name='body'),
}

/**
 * @summary CreateQosPolicy
 *
 * @param tmpReq CreateQosPolicyRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateQosPolicyResponse
 */
async function createQosPolicyWithOptions(tmpReq: CreateQosPolicyRequest, runtime: $RuntimeOptions): CreateQosPolicyResponse {
  tmpReq.validate();
  var request = new CreateQosPolicyShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.flowIds)) {
    request.flowIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.flowIds, 'FlowIds', 'json');
  }
  if (!$isNull(tmpReq.zoneIds)) {
    request.zoneIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.zoneIds, 'ZoneIds', 'json');
  }
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.federationId)) {
    query['FederationId'] = request.federationId;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.flowIdsShrink)) {
    query['FlowIds'] = request.flowIdsShrink;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.maxIOBandWidth)) {
    query['MaxIOBandWidth'] = request.maxIOBandWidth;
  }
  if (!$isNull(request.maxIOps)) {
    query['MaxIOps'] = request.maxIOps;
  }
  if (!$isNull(request.maxMetaQps)) {
    query['MaxMetaQps'] = request.maxMetaQps;
  }
  if (!$isNull(request.zoneIdsShrink)) {
    query['ZoneIds'] = request.zoneIdsShrink;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateQosPolicy',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary CreateQosPolicy
 *
 * @param request CreateQosPolicyRequest
 * @return CreateQosPolicyResponse
 */
async function createQosPolicy(request: CreateQosPolicyRequest): CreateQosPolicyResponse {
  var runtime = new $RuntimeOptions{};
  return createQosPolicyWithOptions(request, runtime);
}

model CreateUserGroupsMappingRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  groupNames?: [ string ](name='GroupNames', example='["group1","group2"]'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  userName?: string(name='UserName', description='This parameter is required.', example='user1'),
}

model CreateUserGroupsMappingShrinkRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  groupNamesShrink?: string(name='GroupNames', example='["group1","group2"]'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  userName?: string(name='UserName', description='This parameter is required.', example='user1'),
}

model CreateUserGroupsMappingResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateUserGroupsMappingResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateUserGroupsMappingResponseBody(name='body'),
}

/**
 * @summary 创建 ugo
 *
 * @param tmpReq CreateUserGroupsMappingRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateUserGroupsMappingResponse
 */
async function createUserGroupsMappingWithOptions(tmpReq: CreateUserGroupsMappingRequest, runtime: $RuntimeOptions): CreateUserGroupsMappingResponse {
  tmpReq.validate();
  var request = new CreateUserGroupsMappingShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.groupNames)) {
    request.groupNamesShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.groupNames, 'GroupNames', 'json');
  }
  var query = OpenApiUtil.query(request.toMap());
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateUserGroupsMapping',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'GET',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary 创建 ugo
 *
 * @param request CreateUserGroupsMappingRequest
 * @return CreateUserGroupsMappingResponse
 */
async function createUserGroupsMapping(request: CreateUserGroupsMappingRequest): CreateUserGroupsMappingResponse {
  var runtime = new $RuntimeOptions{};
  return createUserGroupsMappingWithOptions(request, runtime);
}

model CreateVscMountPointRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='e389e5c7-bcb4-4558-846a-e5afc444****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIds?: [ string ](name='InstanceIds', example='[
      "i-bp1g6zv0ce8oghu7****",
      "i-bp1g6zv0ce8oghu1****"
]'),
}

model CreateVscMountPointShrinkRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='e389e5c7-bcb4-4558-846a-e5afc444****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIdsShrink?: string(name='InstanceIds', example='[
      "i-bp1g6zv0ce8oghu7****",
      "i-bp1g6zv0ce8oghu1****"
]'),
}

model CreateVscMountPointResponseBody = {
  mountPointId?: string(name='MountPointId', example='e389e5c7-bcb4-4558-846a-e5afc444****'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model CreateVscMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: CreateVscMountPointResponseBody(name='body'),
}

/**
 * @param tmpReq CreateVscMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return CreateVscMountPointResponse
 */
async function createVscMountPointWithOptions(tmpReq: CreateVscMountPointRequest, runtime: $RuntimeOptions): CreateVscMountPointResponse {
  tmpReq.validate();
  var request = new CreateVscMountPointShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.instanceIds)) {
    request.instanceIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.instanceIds, 'InstanceIds', 'json');
  }
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.instanceIdsShrink)) {
    query['InstanceIds'] = request.instanceIdsShrink;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'CreateVscMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request CreateVscMountPointRequest
 * @return CreateVscMountPointResponse
 */
async function createVscMountPoint(request: CreateVscMountPointRequest): CreateVscMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return createVscMountPointWithOptions(request, runtime);
}

model DeleteAccessGroupRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model DeleteAccessGroupResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteAccessGroupResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteAccessGroupResponseBody(name='body'),
}

/**
 * @param request DeleteAccessGroupRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteAccessGroupResponse
 */
async function deleteAccessGroupWithOptions(request: DeleteAccessGroupRequest, runtime: $RuntimeOptions): DeleteAccessGroupResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteAccessGroup',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DeleteAccessGroupRequest
 * @return DeleteAccessGroupResponse
 */
async function deleteAccessGroup(request: DeleteAccessGroupRequest): DeleteAccessGroupResponse {
  var runtime = new $RuntimeOptions{};
  return deleteAccessGroupWithOptions(request, runtime);
}

model DeleteAccessRuleRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  accessRuleId?: string(name='AccessRuleId', description='This parameter is required.', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model DeleteAccessRuleResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteAccessRuleResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteAccessRuleResponseBody(name='body'),
}

/**
 * @param request DeleteAccessRuleRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteAccessRuleResponse
 */
async function deleteAccessRuleWithOptions(request: DeleteAccessRuleRequest, runtime: $RuntimeOptions): DeleteAccessRuleResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.accessRuleId)) {
    query['AccessRuleId'] = request.accessRuleId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteAccessRule',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DeleteAccessRuleRequest
 * @return DeleteAccessRuleResponse
 */
async function deleteAccessRule(request: DeleteAccessRuleRequest): DeleteAccessRuleResponse {
  var runtime = new $RuntimeOptions{};
  return deleteAccessRuleWithOptions(request, runtime);
}

model DeleteFileSystemRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model DeleteFileSystemResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteFileSystemResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteFileSystemResponseBody(name='body'),
}

/**
 * @param request DeleteFileSystemRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteFileSystemResponse
 */
async function deleteFileSystemWithOptions(request: DeleteFileSystemRequest, runtime: $RuntimeOptions): DeleteFileSystemResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteFileSystem',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DeleteFileSystemRequest
 * @return DeleteFileSystemResponse
 */
async function deleteFileSystem(request: DeleteFileSystemRequest): DeleteFileSystemResponse {
  var runtime = new $RuntimeOptions{};
  return deleteFileSystemWithOptions(request, runtime);
}

model DeleteMountPointRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.'),
}

model DeleteMountPointResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteMountPointResponseBody(name='body'),
}

/**
 * @param request DeleteMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteMountPointResponse
 */
async function deleteMountPointWithOptions(request: DeleteMountPointRequest, runtime: $RuntimeOptions): DeleteMountPointResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DeleteMountPointRequest
 * @return DeleteMountPointResponse
 */
async function deleteMountPoint(request: DeleteMountPointRequest): DeleteMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return deleteMountPointWithOptions(request, runtime);
}

model DeleteQosPolicyRequest {
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
  qosPolicyId?: string(name='QosPolicyId', description='This parameter is required.'),
}

model DeleteQosPolicyResponseBody = {
  errorMessages?: string(name='ErrorMessages'),
  requestId?: string(name='RequestId'),
}

model DeleteQosPolicyResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteQosPolicyResponseBody(name='body'),
}

/**
 * @summary DeleteQosPolicy
 *
 * @param request DeleteQosPolicyRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteQosPolicyResponse
 */
async function deleteQosPolicyWithOptions(request: DeleteQosPolicyRequest, runtime: $RuntimeOptions): DeleteQosPolicyResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.qosPolicyId)) {
    query['QosPolicyId'] = request.qosPolicyId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteQosPolicy',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary DeleteQosPolicy
 *
 * @param request DeleteQosPolicyRequest
 * @return DeleteQosPolicyResponse
 */
async function deleteQosPolicy(request: DeleteQosPolicyRequest): DeleteQosPolicyResponse {
  var runtime = new $RuntimeOptions{};
  return deleteQosPolicyWithOptions(request, runtime);
}

model DeleteUserGroupsMappingRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  groupNames?: [ string ](name='GroupNames', example='["group1","group2"]'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  userName?: string(name='UserName', description='This parameter is required.', example='user1'),
}

model DeleteUserGroupsMappingShrinkRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  groupNamesShrink?: string(name='GroupNames', example='["group1","group2"]'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  userName?: string(name='UserName', description='This parameter is required.', example='user1'),
}

model DeleteUserGroupsMappingResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteUserGroupsMappingResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteUserGroupsMappingResponseBody(name='body'),
}

/**
 * @summary 删除 ugo
 *
 * @param tmpReq DeleteUserGroupsMappingRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteUserGroupsMappingResponse
 */
async function deleteUserGroupsMappingWithOptions(tmpReq: DeleteUserGroupsMappingRequest, runtime: $RuntimeOptions): DeleteUserGroupsMappingResponse {
  tmpReq.validate();
  var request = new DeleteUserGroupsMappingShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.groupNames)) {
    request.groupNamesShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.groupNames, 'GroupNames', 'json');
  }
  var query = OpenApiUtil.query(request.toMap());
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteUserGroupsMapping',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'GET',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary 删除 ugo
 *
 * @param request DeleteUserGroupsMappingRequest
 * @return DeleteUserGroupsMappingResponse
 */
async function deleteUserGroupsMapping(request: DeleteUserGroupsMappingRequest): DeleteUserGroupsMappingResponse {
  var runtime = new $RuntimeOptions{};
  return deleteUserGroupsMappingWithOptions(request, runtime);
}

model DeleteVscMountPointRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037c****1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
}

model DeleteVscMountPointResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DeleteVscMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DeleteVscMountPointResponseBody(name='body'),
}

/**
 * @param request DeleteVscMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DeleteVscMountPointResponse
 */
async function deleteVscMountPointWithOptions(request: DeleteVscMountPointRequest, runtime: $RuntimeOptions): DeleteVscMountPointResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DeleteVscMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DeleteVscMountPointRequest
 * @return DeleteVscMountPointResponse
 */
async function deleteVscMountPoint(request: DeleteVscMountPointRequest): DeleteVscMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return deleteVscMountPointWithOptions(request, runtime);
}

model DescribeRegionsRequest {
  acceptLanguage?: string(name='AcceptLanguage', example='zh'),
  inputRegionId?: string(name='InputRegionId', example='cn-hangzhou'),
}

model DescribeRegionsResponseBody = {
  regions?: {
    region?: [ 
      {
        localName?: string(name='LocalName'),
        regionEndpoint?: string(name='RegionEndpoint', example='dfs.cn-hangzhou.aliyuncs.com'),
        regionId?: string(name='RegionId', example='cn-hangzhou'),
      }
    ](name='Region'),
  }(name='Regions'),
  requestId?: string(name='RequestId', example='2B51751B-F837-49AA-8EF3-B2B10703****'),
}

model DescribeRegionsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DescribeRegionsResponseBody(name='body'),
}

/**
 * @param request DescribeRegionsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DescribeRegionsResponse
 */
async function describeRegionsWithOptions(request: DescribeRegionsRequest, runtime: $RuntimeOptions): DescribeRegionsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.acceptLanguage)) {
    query['AcceptLanguage'] = request.acceptLanguage;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DescribeRegions',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DescribeRegionsRequest
 * @return DescribeRegionsResponse
 */
async function describeRegions(request: DescribeRegionsRequest): DescribeRegionsResponse {
  var runtime = new $RuntimeOptions{};
  return describeRegionsWithOptions(request, runtime);
}

model DescribeVscMountPointsRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceId?: string(name='InstanceId', example='["ecs-instance1", "ecs-instance2"]'),
  mountPointId?: string(name='MountPointId', example='037cb49e1d-c***5'),
  status?: string(name='Status', example='NORMAL'),
  vscId?: string(name='VscId'),
}

model DescribeVscMountPointsResponseBody = {
  mountPoints?: [ 
    {
      description?: string(name='Description'),
      instanceTotalCount?: int32(name='InstanceTotalCount', example='1'),
      instances?: [ 
        {
          instanceId?: string(name='InstanceId', example='["ecs-instance1", "ecs-instance2"]'),
          status?: string(name='Status', example='AVAILABLE'),
          vscs?: [ 
            {
              vscId?: string(name='VscId'),
              vscStatus?: string(name='VscStatus'),
              vscType?: string(name='VscType'),
            }
          ](name='Vscs'),
        }
      ](name='Instances'),
      mountPointAlias?: string(name='MountPointAlias', example='hdfs1'),
      mountPointId?: string(name='MountPointId', example='037cb49e1d-c***5'),
    }
  ](name='MountPoints'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  totalCount?: int32(name='TotalCount', example='1'),
}

model DescribeVscMountPointsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DescribeVscMountPointsResponseBody(name='body'),
}

/**
 * @param request DescribeVscMountPointsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DescribeVscMountPointsResponse
 */
async function describeVscMountPointsWithOptions(request: DescribeVscMountPointsRequest, runtime: $RuntimeOptions): DescribeVscMountPointsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.instanceId)) {
    query['InstanceId'] = request.instanceId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  if (!$isNull(request.status)) {
    query['Status'] = request.status;
  }
  if (!$isNull(request.vscId)) {
    query['VscId'] = request.vscId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DescribeVscMountPoints',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DescribeVscMountPointsRequest
 * @return DescribeVscMountPointsResponse
 */
async function describeVscMountPoints(request: DescribeVscMountPointsRequest): DescribeVscMountPointsResponse {
  var runtime = new $RuntimeOptions{};
  return describeVscMountPointsWithOptions(request, runtime);
}

model DetachVscMountPointRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIds?: [ string ](name='InstanceIds', example='["ecs-instance1", "ecs-instance2"]'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
  useAssumeRoleChkServerPerm?: boolean(name='UseAssumeRoleChkServerPerm'),
  vscIds?: [ string ](name='VscIds'),
}

model DetachVscMountPointShrinkRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.', example='037****e1d'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  instanceIdsShrink?: string(name='InstanceIds', example='["ecs-instance1", "ecs-instance2"]'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.', example='037cb49e1d-c***5'),
  useAssumeRoleChkServerPerm?: boolean(name='UseAssumeRoleChkServerPerm'),
  vscIdsShrink?: string(name='VscIds'),
}

model DetachVscMountPointResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model DetachVscMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: DetachVscMountPointResponseBody(name='body'),
}

/**
 * @param tmpReq DetachVscMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return DetachVscMountPointResponse
 */
async function detachVscMountPointWithOptions(tmpReq: DetachVscMountPointRequest, runtime: $RuntimeOptions): DetachVscMountPointResponse {
  tmpReq.validate();
  var request = new DetachVscMountPointShrinkRequest{};
  OpenApiUtil.convert(tmpReq, request);
  if (!$isNull(tmpReq.instanceIds)) {
    request.instanceIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.instanceIds, 'InstanceIds', 'json');
  }
  if (!$isNull(tmpReq.vscIds)) {
    request.vscIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.vscIds, 'VscIds', 'json');
  }
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.instanceIdsShrink)) {
    query['InstanceIds'] = request.instanceIdsShrink;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  if (!$isNull(request.useAssumeRoleChkServerPerm)) {
    query['UseAssumeRoleChkServerPerm'] = request.useAssumeRoleChkServerPerm;
  }
  if (!$isNull(request.vscIdsShrink)) {
    query['VscIds'] = request.vscIdsShrink;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'DetachVscMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request DetachVscMountPointRequest
 * @return DetachVscMountPointResponse
 */
async function detachVscMountPoint(request: DetachVscMountPointRequest): DetachVscMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return detachVscMountPointWithOptions(request, runtime);
}

model GetAccessGroupRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model GetAccessGroupResponseBody = {
  accessGroup?: {
    accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
    accessGroupName?: string(name='AccessGroupName', example='test-cluster-policy'),
    createTime?: string(name='CreateTime'),
    description?: string(name='Description'),
    isDefault?: boolean(name='IsDefault', example='false'),
    mountPointCount?: int32(name='MountPointCount', example='1'),
    networkType?: string(name='NetworkType', example='VPC'),
    regionId?: string(name='RegionId', example='cn-hangzhou'),
    ruleCount?: int32(name='RuleCount', example='3'),
  }(name='AccessGroup'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model GetAccessGroupResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: GetAccessGroupResponseBody(name='body'),
}

/**
 * @param request GetAccessGroupRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return GetAccessGroupResponse
 */
async function getAccessGroupWithOptions(request: GetAccessGroupRequest, runtime: $RuntimeOptions): GetAccessGroupResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'GetAccessGroup',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request GetAccessGroupRequest
 * @return GetAccessGroupResponse
 */
async function getAccessGroup(request: GetAccessGroupRequest): GetAccessGroupResponse {
  var runtime = new $RuntimeOptions{};
  return getAccessGroupWithOptions(request, runtime);
}

model GetAccessRuleRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  accessRuleId?: string(name='AccessRuleId', description='This parameter is required.', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model GetAccessRuleResponseBody = {
  accessRule?: {
    accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
    accessRuleId?: string(name='AccessRuleId', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
    createTime?: string(name='CreateTime'),
    description?: string(name='Description'),
    networkSegment?: string(name='NetworkSegment', example='192.0.2.0/24'),
    priority?: int32(name='Priority', example='2'),
    RWAccessType?: string(name='RWAccessType', example='RDWR'),
    regionId?: string(name='RegionId', example='cn-hangzhou'),
  }(name='AccessRule'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model GetAccessRuleResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: GetAccessRuleResponseBody(name='body'),
}

/**
 * @param request GetAccessRuleRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return GetAccessRuleResponse
 */
async function getAccessRuleWithOptions(request: GetAccessRuleRequest, runtime: $RuntimeOptions): GetAccessRuleResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.accessRuleId)) {
    query['AccessRuleId'] = request.accessRuleId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'GetAccessRule',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request GetAccessRuleRequest
 * @return GetAccessRuleResponse
 */
async function getAccessRule(request: GetAccessRuleRequest): GetAccessRuleResponse {
  var runtime = new $RuntimeOptions{};
  return getAccessRuleWithOptions(request, runtime);
}

model GetFileSystemRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model GetFileSystemResponseBody = {
  fileSystem?: {
    createTime?: string(name='CreateTime'),
    description?: string(name='Description'),
    fileSystemId?: string(name='FileSystemId'),
    fileSystemName?: string(name='FileSystemName', example='MyFirstHDFS'),
    meteringSpaceSize?: float(name='MeteringSpaceSize', example='107374182400'),
    mountPointCount?: long(name='MountPointCount', example='2'),
    numberOfDirectories?: long(name='NumberOfDirectories', example='100'),
    numberOfFiles?: long(name='NumberOfFiles', example='1000'),
    protocolType?: string(name='ProtocolType', example='HDFS'),
    provisionedThroughputInMiBps?: long(name='ProvisionedThroughputInMiBps', example='1024'),
    regionId?: string(name='RegionId', example='cn-hangzhou'),
    spaceCapacity?: long(name='SpaceCapacity', example='1024'),
    storagePackageId?: string(name='StoragePackageId', example='1'),
    storageType?: string(name='StorageType', example='STANDARD'),
    throughputMode?: string(name='ThroughputMode', example='Standard'),
    usedSpaceSize?: float(name='UsedSpaceSize', example='100'),
    version?: string(name='Version', example='1.0.0'),
    zoneId?: string(name='ZoneId', example='cn-hangzhou-b'),
  }(name='FileSystem'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model GetFileSystemResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: GetFileSystemResponseBody(name='body'),
}

/**
 * @param request GetFileSystemRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return GetFileSystemResponse
 */
async function getFileSystemWithOptions(request: GetFileSystemRequest, runtime: $RuntimeOptions): GetFileSystemResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'GetFileSystem',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request GetFileSystemRequest
 * @return GetFileSystemResponse
 */
async function getFileSystem(request: GetFileSystemRequest): GetFileSystemResponse {
  var runtime = new $RuntimeOptions{};
  return getFileSystemWithOptions(request, runtime);
}

model GetMountPointRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.'),
}

model GetMountPointResponseBody = {
  mountPoint?: {
    accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
    createTime?: string(name='CreateTime'),
    description?: string(name='Description'),
    fileSystemId?: string(name='FileSystemId'),
    mountPointAlias?: string(name='MountPointAlias'),
    mountPointDomain?: string(name='MountPointDomain'),
    mountPointId?: string(name='MountPointId'),
    networkType?: string(name='NetworkType', example='VPC'),
    regionId?: string(name='RegionId', example='cn-hangzhou'),
    status?: string(name='Status', example='Inactive'),
    vSwitchId?: string(name='VSwitchId', example='vsw-iq8fymi327krd14mt****'),
    vpcId?: string(name='VpcId', example='vpc-iq8hhsk3ymzv9m4wn****'),
  }(name='MountPoint'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model GetMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: GetMountPointResponseBody(name='body'),
}

/**
 * @param request GetMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return GetMountPointResponse
 */
async function getMountPointWithOptions(request: GetMountPointRequest, runtime: $RuntimeOptions): GetMountPointResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'GetMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request GetMountPointRequest
 * @return GetMountPointResponse
 */
async function getMountPoint(request: GetMountPointRequest): GetMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return getMountPointWithOptions(request, runtime);
}

model GetRegionRequest {
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model GetRegionResponseBody = {
  availableZones?: [ 
    {
      options?: [ 
        {
          protocolType?: string(name='ProtocolType', example='HDFS'),
          storageType?: string(name='StorageType', example='STANDARD'),
        }
      ](name='Options'),
      zoneId?: string(name='ZoneId', example='cn-hangzhou-b'),
    }
  ](name='AvailableZones'),
  requestId?: string(name='RequestId', example='AEC07154-5A4C-4B34-BB74-0893C6E9****'),
}

model GetRegionResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: GetRegionResponseBody(name='body'),
}

/**
 * @param request GetRegionRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return GetRegionResponse
 */
async function getRegionWithOptions(request: GetRegionRequest, runtime: $RuntimeOptions): GetRegionResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'GetRegion',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request GetRegionRequest
 * @return GetRegionResponse
 */
async function getRegion(request: GetRegionRequest): GetRegionResponse {
  var runtime = new $RuntimeOptions{};
  return getRegionWithOptions(request, runtime);
}

model ListAccessGroupsRequest {
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  limit?: int32(name='Limit', example='100'),
  nextToken?: string(name='NextToken'),
  orderBy?: string(name='OrderBy', example='CreateTime'),
  orderType?: string(name='OrderType', example='ASC'),
  startOffset?: int32(name='StartOffset', example='10'),
}

model ListAccessGroupsResponseBody = {
  accessGroups?: [ 
    {
      accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
      accessGroupName?: string(name='AccessGroupName', example='test-cluster-policy'),
      createTime?: string(name='CreateTime'),
      description?: string(name='Description'),
      isDefault?: boolean(name='IsDefault', example='false'),
      mountPointCount?: int32(name='MountPointCount', example='1'),
      networkType?: string(name='NetworkType', example='VPC'),
      regionId?: string(name='RegionId', example='cn-hangzhou'),
      ruleCount?: int32(name='RuleCount', example='3'),
    }
  ](name='AccessGroups'),
  nextToken?: string(name='NextToken'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  totalCount?: int32(name='TotalCount', example='1'),
}

model ListAccessGroupsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListAccessGroupsResponseBody(name='body'),
}

/**
 * @param request ListAccessGroupsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListAccessGroupsResponse
 */
async function listAccessGroupsWithOptions(request: ListAccessGroupsRequest, runtime: $RuntimeOptions): ListAccessGroupsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.limit)) {
    query['Limit'] = request.limit;
  }
  if (!$isNull(request.nextToken)) {
    query['NextToken'] = request.nextToken;
  }
  if (!$isNull(request.orderBy)) {
    query['OrderBy'] = request.orderBy;
  }
  if (!$isNull(request.orderType)) {
    query['OrderType'] = request.orderType;
  }
  if (!$isNull(request.startOffset)) {
    query['StartOffset'] = request.startOffset;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListAccessGroups',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ListAccessGroupsRequest
 * @return ListAccessGroupsResponse
 */
async function listAccessGroups(request: ListAccessGroupsRequest): ListAccessGroupsResponse {
  var runtime = new $RuntimeOptions{};
  return listAccessGroupsWithOptions(request, runtime);
}

model ListAccessRulesRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  limit?: int32(name='Limit', example='10'),
  nextToken?: string(name='NextToken'),
  orderBy?: string(name='OrderBy', example='Priority'),
  orderType?: string(name='OrderType', example='ASC'),
  startOffset?: int32(name='StartOffset', example='10'),
}

model ListAccessRulesResponseBody = {
  accessRules?: [ 
    {
      accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
      accessRuleId?: string(name='AccessRuleId', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
      createTime?: string(name='CreateTime'),
      description?: string(name='Description'),
      networkSegment?: string(name='NetworkSegment', example='192.0.2.0/24'),
      priority?: int32(name='Priority', example='2'),
      RWAccessType?: string(name='RWAccessType', example='RDWR'),
      regionId?: string(name='RegionId', example='cn-hangzhou'),
    }
  ](name='AccessRules'),
  nextToken?: string(name='NextToken'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  totalCount?: int32(name='TotalCount', example='1'),
}

model ListAccessRulesResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListAccessRulesResponseBody(name='body'),
}

/**
 * @param request ListAccessRulesRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListAccessRulesResponse
 */
async function listAccessRulesWithOptions(request: ListAccessRulesRequest, runtime: $RuntimeOptions): ListAccessRulesResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.limit)) {
    query['Limit'] = request.limit;
  }
  if (!$isNull(request.nextToken)) {
    query['NextToken'] = request.nextToken;
  }
  if (!$isNull(request.orderBy)) {
    query['OrderBy'] = request.orderBy;
  }
  if (!$isNull(request.orderType)) {
    query['OrderType'] = request.orderType;
  }
  if (!$isNull(request.startOffset)) {
    query['StartOffset'] = request.startOffset;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListAccessRules',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ListAccessRulesRequest
 * @return ListAccessRulesResponse
 */
async function listAccessRules(request: ListAccessRulesRequest): ListAccessRulesResponse {
  var runtime = new $RuntimeOptions{};
  return listAccessRulesWithOptions(request, runtime);
}

model ListFederationsRequest {
  federationId?: string(name='FederationId'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
}

model ListFederationsResponseBody = {
  federations?: [ 
    {
      federationId?: string(name='FederationId'),
      fileSystemIds?: string(name='FileSystemIds'),
    }
  ](name='Federations'),
  requestId?: string(name='RequestId'),
}

model ListFederationsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListFederationsResponseBody(name='body'),
}

/**
 * @summary 查询Federation
 *
 * @param request ListFederationsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListFederationsResponse
 */
async function listFederationsWithOptions(request: ListFederationsRequest, runtime: $RuntimeOptions): ListFederationsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.federationId)) {
    query['FederationId'] = request.federationId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListFederations',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary 查询Federation
 *
 * @param request ListFederationsRequest
 * @return ListFederationsResponse
 */
async function listFederations(request: ListFederationsRequest): ListFederationsResponse {
  var runtime = new $RuntimeOptions{};
  return listFederationsWithOptions(request, runtime);
}

model ListFileSystemsRequest {
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  limit?: int32(name='Limit', example='10'),
  nextToken?: string(name='NextToken'),
  orderBy?: string(name='OrderBy', example='CreateTime'),
  orderType?: string(name='OrderType', example='ASC'),
  startOffset?: int32(name='StartOffset', example='10'),
}

model ListFileSystemsResponseBody = {
  fileSystems?: [ 
    {
      createTime?: string(name='CreateTime'),
      description?: string(name='Description'),
      fileSystemId?: string(name='FileSystemId'),
      fileSystemName?: string(name='FileSystemName', example='MyFirstHDFS'),
      meteringSpaceSize?: float(name='MeteringSpaceSize', example='107374182400'),
      mountPointCount?: long(name='MountPointCount', example='2'),
      numberOfDirectories?: long(name='NumberOfDirectories', example='100'),
      numberOfFiles?: long(name='NumberOfFiles', example='1000'),
      protocolType?: string(name='ProtocolType', example='HDFS'),
      provisionedThroughputInMiBps?: long(name='ProvisionedThroughputInMiBps', example='1024'),
      regionId?: string(name='RegionId', example='cn-hangzhou'),
      spaceCapacity?: long(name='SpaceCapacity', example='1024'),
      storagePackageId?: string(name='StoragePackageId', example='1'),
      storageType?: string(name='StorageType', example='STANDARD'),
      throughputMode?: string(name='ThroughputMode', example='Standard'),
      usedSpaceSize?: float(name='UsedSpaceSize', example='100'),
      version?: string(name='Version', example='1.0.0'),
      zoneId?: string(name='ZoneId', example='cn-hangzhou-b'),
    }
  ](name='FileSystems'),
  nextToken?: string(name='NextToken'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  totalCount?: int32(name='TotalCount', example='1'),
}

model ListFileSystemsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListFileSystemsResponseBody(name='body'),
}

/**
 * @param request ListFileSystemsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListFileSystemsResponse
 */
async function listFileSystemsWithOptions(request: ListFileSystemsRequest, runtime: $RuntimeOptions): ListFileSystemsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.limit)) {
    query['Limit'] = request.limit;
  }
  if (!$isNull(request.nextToken)) {
    query['NextToken'] = request.nextToken;
  }
  if (!$isNull(request.orderBy)) {
    query['OrderBy'] = request.orderBy;
  }
  if (!$isNull(request.orderType)) {
    query['OrderType'] = request.orderType;
  }
  if (!$isNull(request.startOffset)) {
    query['StartOffset'] = request.startOffset;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListFileSystems',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ListFileSystemsRequest
 * @return ListFileSystemsResponse
 */
async function listFileSystems(request: ListFileSystemsRequest): ListFileSystemsResponse {
  var runtime = new $RuntimeOptions{};
  return listFileSystemsWithOptions(request, runtime);
}

model ListMountPointsRequest {
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  limit?: int32(name='Limit', example='10'),
  nextToken?: string(name='NextToken'),
  orderBy?: string(name='OrderBy', example='CreateTime'),
  orderType?: string(name='OrderType', example='ASC'),
  startOffset?: int32(name='StartOffset', example='10'),
}

model ListMountPointsResponseBody = {
  mountPoints?: [ 
    {
      accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
      createTime?: string(name='CreateTime'),
      description?: string(name='Description'),
      fileSystemId?: string(name='FileSystemId'),
      mountPointAlias?: string(name='MountPointAlias'),
      mountPointDomain?: string(name='MountPointDomain'),
      mountPointId?: string(name='MountPointId'),
      networkType?: string(name='NetworkType', example='VPC'),
      regionId?: string(name='RegionId', example='cn-hangzhou'),
      status?: string(name='Status', example='Inactive'),
      vSwitchId?: string(name='VSwitchId', example='vsw-iq8fymi327krd14mt****'),
      vpcId?: string(name='VpcId', example='vpc-iq8hhsk3ymzv9m4wn****'),
    }
  ](name='MountPoints'),
  nextToken?: string(name='NextToken'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  totalCount?: int32(name='TotalCount', example='1'),
}

model ListMountPointsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListMountPointsResponseBody(name='body'),
}

/**
 * @param request ListMountPointsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListMountPointsResponse
 */
async function listMountPointsWithOptions(request: ListMountPointsRequest, runtime: $RuntimeOptions): ListMountPointsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.limit)) {
    query['Limit'] = request.limit;
  }
  if (!$isNull(request.nextToken)) {
    query['NextToken'] = request.nextToken;
  }
  if (!$isNull(request.orderBy)) {
    query['OrderBy'] = request.orderBy;
  }
  if (!$isNull(request.orderType)) {
    query['OrderType'] = request.orderType;
  }
  if (!$isNull(request.startOffset)) {
    query['StartOffset'] = request.startOffset;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListMountPoints',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ListMountPointsRequest
 * @return ListMountPointsResponse
 */
async function listMountPoints(request: ListMountPointsRequest): ListMountPointsResponse {
  var runtime = new $RuntimeOptions{};
  return listMountPointsWithOptions(request, runtime);
}

model ListQosPoliciesRequest {
  federationId?: string(name='FederationId'),
  fileSystemId?: string(name='FileSystemId'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
}

model ListQosPoliciesResponseBody = {
  qosPolicies?: [ 
    {
      description?: string(name='Description'),
      federationId?: string(name='FederationId'),
      fileSystemId?: string(name='FileSystemId'),
      flowIds?: string(name='FlowIds'),
      maxIOBandWidth?: long(name='MaxIOBandWidth'),
      maxIOps?: long(name='MaxIOps'),
      maxMetaQps?: long(name='MaxMetaQps'),
      qosPolicyId?: string(name='QosPolicyId'),
      zoneIds?: string(name='ZoneIds'),
    }
  ](name='QosPolicies'),
  requestId?: string(name='RequestId'),
}

model ListQosPoliciesResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListQosPoliciesResponseBody(name='body'),
}

/**
 * @summary 查询QosPolicies
 *
 * @param request ListQosPoliciesRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListQosPoliciesResponse
 */
async function listQosPoliciesWithOptions(request: ListQosPoliciesRequest, runtime: $RuntimeOptions): ListQosPoliciesResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.federationId)) {
    query['FederationId'] = request.federationId;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListQosPolicies',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary 查询QosPolicies
 *
 * @param request ListQosPoliciesRequest
 * @return ListQosPoliciesResponse
 */
async function listQosPolicies(request: ListQosPoliciesRequest): ListQosPoliciesResponse {
  var runtime = new $RuntimeOptions{};
  return listQosPoliciesWithOptions(request, runtime);
}

model ListUserGroupsMappingsRequest {
  filesystemId?: string(name='FilesystemId', description='This parameter is required.', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  limit?: int32(name='Limit', example='10'),
  nextToken?: string(name='NextToken', example='user1'),
}

model ListUserGroupsMappingsResponseBody = {
  hasMore?: boolean(name='HasMore', example='true'),
  nextToken?: string(name='NextToken', example='user1'),
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
  userGroupsMappings?: [ 
    {
      groupNames?: [ string ](name='GroupNames'),
      userName?: string(name='UserName', example='user1'),
    }
  ](name='UserGroupsMappings'),
}

model ListUserGroupsMappingsResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ListUserGroupsMappingsResponseBody(name='body'),
}

/**
 * @summary list ugm
 *
 * @param request ListUserGroupsMappingsRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ListUserGroupsMappingsResponse
 */
async function listUserGroupsMappingsWithOptions(request: ListUserGroupsMappingsRequest, runtime: $RuntimeOptions): ListUserGroupsMappingsResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.filesystemId)) {
    query['FilesystemId'] = request.filesystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.limit)) {
    query['Limit'] = request.limit;
  }
  if (!$isNull(request.nextToken)) {
    query['NextToken'] = request.nextToken;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ListUserGroupsMappings',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @summary list ugm
 *
 * @param request ListUserGroupsMappingsRequest
 * @return ListUserGroupsMappingsResponse
 */
async function listUserGroupsMappings(request: ListUserGroupsMappingsRequest): ListUserGroupsMappingsResponse {
  var runtime = new $RuntimeOptions{};
  return listUserGroupsMappingsWithOptions(request, runtime);
}

model ModifyAccessGroupRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  accessGroupName?: string(name='AccessGroupName', example='my-online-cluster-policy'),
  description?: string(name='Description'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
}

model ModifyAccessGroupResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model ModifyAccessGroupResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ModifyAccessGroupResponseBody(name='body'),
}

/**
 * @param request ModifyAccessGroupRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ModifyAccessGroupResponse
 */
async function modifyAccessGroupWithOptions(request: ModifyAccessGroupRequest, runtime: $RuntimeOptions): ModifyAccessGroupResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.accessGroupName)) {
    query['AccessGroupName'] = request.accessGroupName;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ModifyAccessGroup',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ModifyAccessGroupRequest
 * @return ModifyAccessGroupResponse
 */
async function modifyAccessGroup(request: ModifyAccessGroupRequest): ModifyAccessGroupResponse {
  var runtime = new $RuntimeOptions{};
  return modifyAccessGroupWithOptions(request, runtime);
}

model ModifyAccessRuleRequest {
  accessGroupId?: string(name='AccessGroupId', description='This parameter is required.', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  accessRuleId?: string(name='AccessRuleId', description='This parameter is required.', example='acr-c38028f0-f313-4385-9456-3501b1f5****'),
  description?: string(name='Description'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  priority?: int32(name='Priority', example='2'),
  RWAccessType?: string(name='RWAccessType', example='RDWR'),
}

model ModifyAccessRuleResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model ModifyAccessRuleResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ModifyAccessRuleResponseBody(name='body'),
}

/**
 * @param request ModifyAccessRuleRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ModifyAccessRuleResponse
 */
async function modifyAccessRuleWithOptions(request: ModifyAccessRuleRequest, runtime: $RuntimeOptions): ModifyAccessRuleResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.accessRuleId)) {
    query['AccessRuleId'] = request.accessRuleId;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.priority)) {
    query['Priority'] = request.priority;
  }
  if (!$isNull(request.RWAccessType)) {
    query['RWAccessType'] = request.RWAccessType;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ModifyAccessRule',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ModifyAccessRuleRequest
 * @return ModifyAccessRuleResponse
 */
async function modifyAccessRule(request: ModifyAccessRuleRequest): ModifyAccessRuleResponse {
  var runtime = new $RuntimeOptions{};
  return modifyAccessRuleWithOptions(request, runtime);
}

model ModifyFileSystemRequest {
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  fileSystemName?: string(name='FileSystemName', example='MyFirstModDFS'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  provisionedThroughputInMiBps?: long(name='ProvisionedThroughputInMiBps', example='1024'),
  spaceCapacity?: long(name='SpaceCapacity', example='1024'),
  throughputMode?: string(name='ThroughputMode', example='Standard'),
}

model ModifyFileSystemResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model ModifyFileSystemResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ModifyFileSystemResponseBody(name='body'),
}

/**
 * @param request ModifyFileSystemRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ModifyFileSystemResponse
 */
async function modifyFileSystemWithOptions(request: ModifyFileSystemRequest, runtime: $RuntimeOptions): ModifyFileSystemResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.fileSystemName)) {
    query['FileSystemName'] = request.fileSystemName;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.provisionedThroughputInMiBps)) {
    query['ProvisionedThroughputInMiBps'] = request.provisionedThroughputInMiBps;
  }
  if (!$isNull(request.spaceCapacity)) {
    query['SpaceCapacity'] = request.spaceCapacity;
  }
  if (!$isNull(request.throughputMode)) {
    query['ThroughputMode'] = request.throughputMode;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ModifyFileSystem',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ModifyFileSystemRequest
 * @return ModifyFileSystemResponse
 */
async function modifyFileSystem(request: ModifyFileSystemRequest): ModifyFileSystemResponse {
  var runtime = new $RuntimeOptions{};
  return modifyFileSystemWithOptions(request, runtime);
}

model ModifyMountPointRequest {
  accessGroupId?: string(name='AccessGroupId', example='acg-e3755fb0-358d-4286-9942-8d461048****'),
  description?: string(name='Description'),
  fileSystemId?: string(name='FileSystemId', description='This parameter is required.'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.', example='cn-hangzhou'),
  mountPointId?: string(name='MountPointId', description='This parameter is required.'),
  status?: string(name='Status', example='Inactive'),
}

model ModifyMountPointResponseBody = {
  requestId?: string(name='RequestId', example='55C5FFD6-BF99-41BD-9C66-FFF39189****'),
}

model ModifyMountPointResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ModifyMountPointResponseBody(name='body'),
}

/**
 * @param request ModifyMountPointRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ModifyMountPointResponse
 */
async function modifyMountPointWithOptions(request: ModifyMountPointRequest, runtime: $RuntimeOptions): ModifyMountPointResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.accessGroupId)) {
    query['AccessGroupId'] = request.accessGroupId;
  }
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.fileSystemId)) {
    query['FileSystemId'] = request.fileSystemId;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.mountPointId)) {
    query['MountPointId'] = request.mountPointId;
  }
  if (!$isNull(request.status)) {
    query['Status'] = request.status;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ModifyMountPoint',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ModifyMountPointRequest
 * @return ModifyMountPointResponse
 */
async function modifyMountPoint(request: ModifyMountPointRequest): ModifyMountPointResponse {
  var runtime = new $RuntimeOptions{};
  return modifyMountPointWithOptions(request, runtime);
}

model ModifyQosPolicyRequest {
  description?: string(name='Description'),
  inputRegionId?: string(name='InputRegionId', description='This parameter is required.'),
  maxIOBandWidth?: long(name='MaxIOBandWidth'),
  maxIOps?: long(name='MaxIOps'),
  maxMetaQps?: long(name='MaxMetaQps'),
  qosPolicyId?: string(name='QosPolicyId', description='This parameter is required.'),
}

model ModifyQosPolicyResponseBody = {
  requestId?: string(name='RequestId'),
}

model ModifyQosPolicyResponse = {
  headers?: map[string]string(name='headers'),
  statusCode?: int32(name='statusCode'),
  body?: ModifyQosPolicyResponseBody(name='body'),
}

/**
 * @param request ModifyQosPolicyRequest
 * @param runtime runtime options for this request RuntimeOptions
 * @return ModifyQosPolicyResponse
 */
async function modifyQosPolicyWithOptions(request: ModifyQosPolicyRequest, runtime: $RuntimeOptions): ModifyQosPolicyResponse {
  request.validate();
  var query = {};
  if (!$isNull(request.description)) {
    query['Description'] = request.description;
  }
  if (!$isNull(request.inputRegionId)) {
    query['InputRegionId'] = request.inputRegionId;
  }
  if (!$isNull(request.maxIOBandWidth)) {
    query['MaxIOBandWidth'] = request.maxIOBandWidth;
  }
  if (!$isNull(request.maxIOps)) {
    query['MaxIOps'] = request.maxIOps;
  }
  if (!$isNull(request.maxMetaQps)) {
    query['MaxMetaQps'] = request.maxMetaQps;
  }
  if (!$isNull(request.qosPolicyId)) {
    query['QosPolicyId'] = request.qosPolicyId;
  }
  var req = new OpenApiUtil.OpenApiRequest{ 
    query = OpenApiUtil.query(query),
  };
  var params = new OpenApiUtil.Params{
    action = 'ModifyQosPolicy',
    version = '2018-06-20',
    protocol = 'HTTPS',
    pathname = '/',
    method = 'POST',
    authType = 'AK',
    style = 'RPC',
    reqBodyType = 'formData',
    bodyType = 'json',
  };
  return callApi(params, req, runtime);
}

/**
 * @param request ModifyQosPolicyRequest
 * @return ModifyQosPolicyResponse
 */
async function modifyQosPolicy(request: ModifyQosPolicyRequest): ModifyQosPolicyResponse {
  var runtime = new $RuntimeOptions{};
  return modifyQosPolicyWithOptions(request, runtime);
}

